<!DOCTYPE html>
<!-- saved from url=(0040)https://sns.tianqiapi.com/sns/userNotice -->
<html lang="zh-cn"><head><meta http-equiv="Content-Type" content="text/html; charset=UTF-8">
    
    <meta name="author" content="聊天室系统配置服务 QQ: 445899710 微信: hype522147">
    <meta name="viewport" content="width=device-width, initial-scale=1, minimum-scale=1, maximum-scale=1, user-scalable=no">
    <title>微聊</title>
    <link rel="icon" href="https://sns.tianqiapi.com/favicon.ico" type="image/x-icon">
    <link rel="stylesheet" href="./我的-新消息通知_files/weui.min.css">
    <link rel="stylesheet" href="./我的-新消息通知_files/layer.css">
    <link rel="stylesheet" href="./我的-新消息通知_files/app.css">
        <style>
        body {
            background: #ededed;
        }
    </style>
<link rel="stylesheet" href="./我的-新消息通知_files/layer(1).css" id="layuicss-layer"></head>
<body>
    <!--navbar-->
    <div class="navbar">新消息通知<img class="btnleft" src="./我的-新消息通知_files/left.png"></div>
    <div class="line40"></div>

    <div class="weui-cells">
        <div class="weui-cell " href="javascript:;">
            <div class="weui-cell__bd">
                <p>接收新消息通知</p>
            </div>
            <div class="weui-cell__ft"><input id="mycheckbox" class="weui-switch" type="checkbox" checked="checked" onchange="changesecret()"></div>
        </div>
    </div>
<script type="text/javascript" src="./我的-新消息通知_files/jquery.min.js"></script>
<script type="text/javascript" src="./我的-新消息通知_files/layer.js"></script>
<script type="text/javascript" src="./我的-新消息通知_files/app.js"></script>
<script>
    function changesecret() {
        if($('#mycheckbox').is(':checked')) {
            inputtext = 1
        } else {
            inputtext = 2
        }
        $.ajax({
            type: 'POST',
            url: '/sns/usersave',
            data: 'ctype=notice&inputtext=' + inputtext,
            dataType: 'JSON',
            error: function () {
                layer.alert('网络错误');
            },
            success: function (res) {
                if (res.errcode == 0) {
                    layer.msg(res.errmsg);
                } else {
                    layer.msg(res.errmsg);
                }
            }
        });
    }
</script>

</body></html>